/**
 Copyright will be fixed soon.
 Author: Hiroshi Ota.
 $Date: $
 $Revision: $
*/

#ifndef _BF_STATE_H_
#define _BF_STATE_H_

class BFState
{
public:
	enum SystemState {
		SS_NONE           = 0,
		SS_INITIALIZATION = 1,
		SS_RUNNING        = 2,
		SS_TERMINATION    = 3,
		SS_UNKNOWN        = 16
	};

	enum StairingDir {
		SD_OFF   = 0,
		SD_LEFT  = 1,
		SD_RIGHT = 2,
		SD_BRAKE = 3
	};

	enum DriveDir {
		DD_OFF      = 0,
		DD_FORWARD  = 1,
		DD_BACKWARD = 2,
		DD_BRAKE    = 3
	};

	BFState(void);
	BFState(BFState& src);
	virtual ~BFState(void);

	void setSystemState(SystemState systemState) {
		cSysState = systemState;
	}

	SystemState getSystemState() { return cSysState; }

	StairingDir currentStairingDir;
	unsigned char currentStairingLevel;

	DriveDir currentDriveDir;
	unsigned char currentDriveLevel;

	unsigned int currentLightSensorLevel;
	bool touchSensorPressed;

	bool preJudgePhase;

	void copy(BFState* src);

private:
	SystemState cSysState;


};

#endif //  _BF_STATE_H_
